FROM openjdk:8-jdk-alpine
# 指定维护者名称
MAINTAINER wangheng wangheng@geewaza.com

ARG APP_JAR="./target/app.jar"
ARG JAVA_OPTS="-Duser.timezone=GMT+08 -Dspring.profiles.active=prod"

VOLUME /tmp

#RUN apk --no-cache add tzdata ttf-dejavu && \
#    ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
#    echo "Asia/Shanghai" > /etc/timezone

COPY ${APP_JAR} app.jar

ENV JAVA_OPTS=""

EXPOSE 8080

ENTRYPOINT java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /app.jar
